package thinkinginjava.designmode;

class Singleton{
	private  static Singleton instance = new Singleton();
	private Singleton(){	
	}
	public static Singleton getInstance(){
		return instance;
	}
	public void test(){
		System.out.println("------------test------------");
	}
}
public class SingletonPatternTest01 {
	public static void main(String[] args){
//      Singleton s1 = new Singleton();
	   Singleton.getInstance().test();      
	   }
}
